Optimal. Leaf size=30 \[ -\frac{d \tanh ^{-1}(\cos (a+b x))}{b^2}-\frac{(c+d x) \csc (a+b x)}{b} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0195758, antiderivative size = 30, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 2, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.111, Rules used = {4410, 3770} \[ -\frac{d \tanh ^{-1}(\cos (a+b x))}{b^2}-\frac{(c+d x) \csc (a+b x)}{b} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 4410
Rule 3770
Rubi steps
\begin{align*} \int (c+d x) \cot (a+b x) \csc (a+b x) \, dx &=-\frac{(c+d x) \csc (a+b x)}{b}+\frac{d \int \csc (a+b x) \, dx}{b}\\ &=-\frac{d \tanh ^{-1}(\cos (a+b x))}{b^2}-\frac{(c+d x) \csc (a+b x)}{b}\\ \end{align*}
Mathematica [B] time = 0.0584151, size = 131, normalized size = 4.37 \[ \frac{d \log \left (\sin \left (\frac{a}{2}+\frac{b x}{2}\right )\right )}{b^2}-\frac{d \log \left (\cos \left (\frac{a}{2}+\frac{b x}{2}\right )\right )}{b^2}-\frac{c \csc (a+b x)}{b}-\frac{d x \csc (a)}{b}+\frac{d x \csc \left (\frac{a}{2}\right ) \sin \left (\frac{b x}{2}\right ) \csc \left (\frac{a}{2}+\frac{b x}{2}\right )}{2 b}-\frac{d x \sec \left (\frac{a}{2}\right ) \sin \left (\frac{b x}{2}\right ) \sec \left (\frac{a}{2}+\frac{b x}{2}\right )}{2 b} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.024, size = 52, normalized size = 1.7 \begin{align*} -{\frac{dx}{b\sin \left ( bx+a \right ) }}+{\frac{d\ln \left ( \csc \left ( bx+a \right ) -\cot \left ( bx+a \right ) \right ) }{{b}^{2}}}-{\frac{c}{b\sin \left ( bx+a \right ) }} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [B] time = 1.09171, size = 350, normalized size = 11.67 \begin{align*} -\frac{\frac{{\left (4 \,{\left (b x + a\right )} \cos \left (b x + a\right ) \sin \left (2 \, b x + 2 \, a\right ) - 4 \,{\left (b x + a\right )} \cos \left (2 \, b x + 2 \, a\right ) \sin \left (b x + a\right ) +{\left (\cos \left (2 \, b x + 2 \, a\right )^{2} + \sin \left (2 \, b x + 2 \, a\right )^{2} - 2 \, \cos \left (2 \, b x + 2 \, a\right ) + 1\right )} \log \left (\cos \left (b x + a\right )^{2} + \sin \left (b x + a\right )^{2} + 2 \, \cos \left (b x + a\right ) + 1\right ) -{\left (\cos \left (2 \, b x + 2 \, a\right )^{2} + \sin \left (2 \, b x + 2 \, a\right )^{2} - 2 \, \cos \left (2 \, b x + 2 \, a\right ) + 1\right )} \log \left (\cos \left (b x + a\right )^{2} + \sin \left (b x + a\right )^{2} - 2 \, \cos \left (b x + a\right ) + 1\right ) + 4 \,{\left (b x + a\right )} \sin \left (b x + a\right )\right )} d}{{\left (\cos \left (2 \, b x + 2 \, a\right )^{2} + \sin \left (2 \, b x + 2 \, a\right )^{2} - 2 \, \cos \left (2 \, b x + 2 \, a\right ) + 1\right )} b} + \frac{2 \, c}{\sin \left (b x + a\right )} - \frac{2 \, a d}{b \sin \left (b x + a\right )}}{2 \, b} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 0.488275, size = 181, normalized size = 6.03 \begin{align*} -\frac{2 \, b d x + d \log \left (\frac{1}{2} \, \cos \left (b x + a\right ) + \frac{1}{2}\right ) \sin \left (b x + a\right ) - d \log \left (-\frac{1}{2} \, \cos \left (b x + a\right ) + \frac{1}{2}\right ) \sin \left (b x + a\right ) + 2 \, b c}{2 \, b^{2} \sin \left (b x + a\right )} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F] time = 0., size = 0, normalized size = 0. \begin{align*} \int \left (c + d x\right ) \cos{\left (a + b x \right )} \csc ^{2}{\left (a + b x \right )}\, dx \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.52748, size = 1081, normalized size = 36.03 \begin{align*} \text{result too large to display} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]